package com.flw.eslab.adapter;


public interface SwitchState<T,R>{
	
	public R toDto(T entity);
	public T toVo(R entity);
	/*public User_Dto 2Dto() {
		return new User_Dto(studentNO, password, name, id);
	}
	
	// User_Dto转换成User对象
		public User 2User() {
			return new User(password,email,studentNO);
		}
		public Info toInfo() {
			return new Info(title, content, author, kind);
		}
		public Project toProject(Set<User> users) {
			try {
				time = new SimpleDateFormat("yyyy-MM-dd").parse(year + "-" + month
						+ "-" + day);
			} catch (ParseException e) {
				e.printStackTrace();
			}
			System.out.println("time:" + time);
			return new Project(title, content, keytech, picurl, state, time, kind,
					detail, users);
		}

		public Report toReport(User user) {
			return new Report(user, content, solution, question, nextplan);
		}
		public Resource toResource(User user) {
			return new Resource(user, name, url, kind, brief);
		}
		
		public Task toTask()
		{
			
			t_start.replaceAll("/", "-");
			t_end.replaceAll("/", "-");
			
			return new Task(t_name,t_desc,Date.valueOf(t_start),Date.valueOf(t_end),t_state,t_temp);
		}
*/

}
